home *** CD-ROM | disk | FTP | other *** search
-
-
-
-
-
-
- ASC-SCR
-
-
-
- The ASCII to Script File Conversion Utility
-
-
-
-
- Version 2.1
-
-
-
-
-
-
-
-
-
- USERS' MANUAL
-
-
-
-
-
-
-
-
- Program Developed and Written by:
-
- Michael S. Campbell
- and
- Douglas A. Pickell, P.E.
-
-
-
-
-
-
-
-
-
-
- HydraWare Software
-
- 8207 Sugarbush Court
-
- Orlando, Florida 32819 USA
-
-
-
-
- TABLE OF CONTENTS
-
-
-
- Section Title Page
-
- License Agreement .................................................. 2
-
- 1 What Is ASC-SCR .............................................. 4
-
- 2 Installing ASC-SCR ........................................... 5
-
- 3 Using ASC-SCR ................................................ 6
-
- 4 Examples ..................................................... 9
-
- 5 Questions or Problems ....................................... 10
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- Copyright (c) 1991 HydraWare Software (HWS).
- All rights reserved worldwide. Unauthorized duplication prohibited.
-
-
- Documentation by Douglas A. Pickell, P.E.
-
- This manual was developed using WordPerfect and the Norton Editor.
-
-
- June 1991 Release
-
-
-
-
-
-
- ASC-SCR 2.1 Page 1
- LICENSE AGREEMENT
-
-
- The ASC-SCR Program is NOT "Public Domain" and it is NOT "Freeware". It is
- a copyrighted software product developed and owned by HydraWare Software
- (HWS) located in Orlando, Florida, U.S.A. HWS grants you without charge
- the right to reproduce, distribute and use copies of this version of our
- shareware software product, subject to the limitations specified below,
- and on the express condition that you do not receive any payment,
- commercial benefit, or other consideration for such reproduction or
- distribution, or change this license agreement or the following copyright
- notice which appears in the software, documentation, or other related
- files:
-
-
- Copyright (c) 1991 HydraWare(R) Software (HWS).
- All rights reserved worldwide. No unauthorized duplication allowed.
-
-
- Limitations:
-
- You may make and keep one (1) back-up copy of the software for your
- personal use, provided that (i) you have registered, and (ii) you
- copy all the copyright, name, and other information shown on the
- initial screen display banner (or on the diskette label, for the
- registered version disk) onto your backup diskette label.
-
- You may distribute copies to other persons, but solely for their
- evaluation to determine whether to continue using the product and
- therefore register; said evaluation period to not exceed twenty-one
- (21) days.
-
- ASC-SCR may NOT be sold or otherwise provided as part of any other
- system, without express written consent and licensing from HWS. The
- rights to receive any such financial or other benefit, and to
- modify the product or employ its components in any kind of
- derivative work, are reserved exclusively by HydraWare Software!
-
-
-
-
- Support from users enables us to develop additional features and future
- versions of ASC-SCR and other HWS products. Registered users benefit from
- receipt of the latest program version, free minor updates, price discounts
- for major upgrades, and notice of new products. Also, please feel free to
- contribute your ideas regarding desired additional product features and
- functionality. Contact us at:
-
- HydraWare Software
- 8207 Sugarbush Court
- Orlando, Florida 32819 USA
-
-
-
-
-
-
-
-
- ASC-SCR 2.1 Page 2
-
-
- BY USING THE ASC-SCR PRODUCT, YOU AGREE THAT NEITHER
- HYDRAWARE SOFTWARE NOR ANY OTHER RELATED PARTIES WILL BE
- LIABLE TO YOU OR ANY THIRD PARTY FOR ANY USE OF (OR
- INABILITY TO USE) OR PERFORMANCE OF THIS PRODUCT, OR FOR ANY
- DAMAGES WHATSOEVER WHETHER BASED ON CONTRACT, TORT OR
- OTHERWISE.
- HydraWare Software warrants to owners of registered copies of this program
- that the software will operate in substantial conformance with the
- description given in the documentation, and that the diskettes will be
- free of physical defects which interfere with normal use. For a period of
- 30 days from the date of your purchase, HWS will, at its sole option and
- subject to the restrictions above and below, replace any defective item(s),
- if such defect is the fault of HWS and not the result of misuse or abuse.
- Such a replacement shall be your sole remedy for any defects, program
- error(s), or documentation error(s). In no event shall HWS be responsible
- for any other costs or damages whatsoever due to errors in usage or your
- failure to read, understand, or follow instructions in the documentation.
- HydraWare Software MAKES NO OTHER WARRANTIES, EXPRESS OR IMPLIED,
- INCLUDING WITHOUT LIMITATION THE WARRANTIES OF MERCHANTABILITY AND OF
- FITNESS FOR A PARTICULAR PURPOSE. HWS's warranty is expressly limited to
- the cost of replacement of any defective diskette.
-
-
-
-
- You may not reverse-engineer, disassemble, modify, decompile or create
- derivative works of this product. You acknowledge that the product
- includes certain trade secrets and confidential information, all of which
- is the copyrighted intellectual property of HydraWare Software.
-
-
- AutoCAD is a registered trademark of Autodesk, Inc.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- ASC-SCR 2.1 Page 3
- SECTION 1
-
- What is ASC-SCR
-
- ASC-SCR is an acronym that stands for "ASCII to Script". In other words,
- this is a utility program that converts an ASCII file to a Script file.
-
- Another common name for an ASCII (which stands for American Standard Code
- for Information Interchange) file is a "text" file, which simply means that
- it has no control or special characters (like a word processor would embed
- in a file) and can be viewed directly with the DOS 'type' command or sent
- directly to a printer with the DOS 'print' command. ASCII files can be
- created or modified with a "text editor" or with a word processor in text
- or ASCII mode. Of course, many programs like spreadsheet, database, and
- other engineering programs often produce output in ASCII format.
-
- A "script" file is a file type used by AutoCAD. It is a series of AutoCAD
- commands, answers to questions prompted by these commands, and data that
- is required by these commands. It is very much like a DOS batch file or a
- spreadsheet macro. The script command is issued from within AutoCAD and
- the user responds with the script file's name. All of the commands,
- answers, and data within the script file are then automatically entered
- into AutoCAD just as if the user had typed the responses at the keyboard!
- This method can be a very easy and powerful way to transfer large amounts
- of data into AutoCAD. Consult your AutoCAD reference for more detailed
- information on script files.
-
- ASC-SCR is written in C and compiled with Borland's C++ compiler. Source
- code is not supplied. The executable itself is not copy protected. On
- screen help is available at all times by using the "-h" or "-?" option.
- The program supports CGA (color), MDA (monochrome), EGA (Enhanced Graphics
- Adapter), VGA (Video Graphics Array) and Hercules graphics adapter displays
- and has the Borland BGI video drivers compiled into it.
-
- We value and welcome user comments and suggestions concerning the software
- and the documentation. Please feel free to write or use the comment form
- provided with this documentation to give us your reactions to this product.
- All user comments are carefully considered in our continuing effort to
- improve the program and its documentation. Thank you for purchasing
- ASC-SCR, which we hope you find easy to use and powerful in its abilities.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- ASC-SCR 2.1 Page 4
- SECTION 2
-
- Installing ASC-SCR
-
- The files listed below comprise the ASC-SCR package. If it isn't obvious,
- their functions are listed. You may place your distribution disk in
- Drive A: and give the "DIR A:" command to see the listing of these files.
-
-
- ASC-SCR.EXE The ASC-SCR program
-
- MANUAL.DOC This document
-
- EXAMPLE.DAT Example input data file
-
- ORDER.DOC An order and comment form
-
- INSTALL.BAT Simple batch file to copy files to hard drive
-
- README.1ST Pertinent initial info to know
-
- RUN1ST.BAT Batch file that lists README.1ST to screen
- and executes INSTALL.BAT
-
- For your ease, we have provided a simple install procedure; however, using
- it is not required to install ASC-SCR. Since the program is not in any
- type of compressed format, you may simply copy it from the distribution
- floppy disk to the desired location on your hard drive. If you plan to
- use ASC-SCR from a floppy, make a backup/working copy of the program
- diskette for day-to-day use. Store the original in a safe place.
-
- The program consists of a single, stand-alone executable (.EXE file) with
- no additional files required for the program to run and function properly.
- Technically, ASC-SCR may be run from any subdirectory of a hard drive or
- from a floppy drive. The other files that you find on your distribution
- disk are documentation and an example. While they should be kept with the
- program file, they are not necessary for its use.
-
- ASC-SCR is an AutoCAD utility, so you will probably want to have it
- available for use with your AutoCAD program. You may accomplish this by
- locating ASC-SCR with your other AutoCAD utilities somewhere in your Auto-
- CAD subdirectory hierarchy. Alternatively, you may copy the program to
- its own subdirectory, or any general purpose utility subdirectory, and
- then add this subdirectory to your path.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- ASC-SCR 2.1 Page 5
- SECTION 3
-
- Using ASC-SCR
-
- ASC-SCR is an AutoCAD utility program that was written to convert any ASCII
- file ("text" file) of x, y, and optionally z, coordinates into an AutoCAD
- script file. This ASCII file could have been generated from many different
- sources. For instance, it may be output from some other program; come from
- a spreadsheet; been exported from a database program; or simply input by
- the user with a text editor.
-
- Because of all these potential sources, the ASCII file may be in many
- different formats. The formats that ASC-SCR currently supports are:
- space delimited (SDF), comma delimited (CDF), and apostrophe (') or quote
- mark (") delimited. The example data file (EXAMPLE.DAT) included with the
- distribution files has samples of each of these formats. Although we mixed
- formats in our example file for purposes of illustration, you would
- normally only have a single format in the file.
-
- ASC-SCR is completely command line driven, meaning that all available
- options for processing the data must be entered on the command line,
- including the filename(s) to be processed. If the user types the program
- name only, a usage screen will be shown (see below for detailed information
- on usage). If no program options are entered, the defaults are assumed and
- used to process the input file(s). The defaults are: create a script
- file(s) that makes a polyline of two dimensional (x & y) coordinates,
- giving the output file(s) the same prefix name as the input file(s) but
- with an ".scr" extension.
-
-
- The syntax for ASC-SCR is shown below. Details of usage follows. This
- information is essentially the same as what will be seen on the screen if
- the user types the program name without any other command line parameters:
-
- asc-scr [option(s)] input_file [ [option(s)] input_file ] ...
-
- The "[]" indicate non-required information and the "..." indicate the
- syntax may be repeated indefinitely as required.
-
-
- The listing below shows all the available options to ASC-SCR. When used,
- the "|" indicates related switches, where one or the other is used; the
- "<>" indicates other additional data is required with this option; and "/"
- delimits the allowable choices for an item using the "<>". Although the
- options are shown with the "-" as the command line delimiter, the "/" is
- also acceptable (these two being the most universally used).
-
- -h = review Help -- you will be able to page through a series of
- detailed help screens and examples; at the conclusion of help
- review, you will be returned to the DOS prompt, therefore any
- other options and filename(s) are ignored
-
- -? = review this usage data AND review help -- the most assistance that
- you can get! See the usage screen and then opt to review the help
-
-
-
-
- ASC-SCR 2.1 Page 6
- SECTION 3
-
-
- -i|q = for non-fatal error(s) only you may:
- i=Ignore the error (you will always get some informational
- message to the screen) and continue processing the file
- q=Quit all processing and terminate the program (DEFAULT)
-
- -3|2 = process the data in the input file as:
- 3=3-D points (x,y,z)
- 2=2-D points (x,y) (DEFAULT)
-
- -p|n|b<fn_block> = the output script file will:
- p=create a Polyline using the coordinates (DEFAULT)
- n=insert Nodes (points) only at each coordinate
- b=insert the drawing Block "fn_block" at each coordinate --
- "fn_block" may be any existing valid AutoCAD .dwg file and a
- full path may be specified, but do NOT include the ".dwg"
- extension
-
- -g|x<dap> = the output script file:
- g=will be Given the AutoCAD script file ".scr" extension (DEFAULT)
- x=will have its eXtension changed to ".dap"
-
-
- It is also possible to perform some rudimentary arithmetic on the data
- contained in the input file(s). The "-s" options give you that flexibility.
-
- -s<x#/y#/z#> = Scale only the x OR y OR z axis values by the number '#'
- -- the number provided will be used to multiply just the values of
- the axis specified, for all points
-
- -su<#> = Scale Uniformly all axes values by the number '#' -- the number
- provided will be used to multiply all values in the file, for 2-D
- or 3-D as applicable
-
- -sa<x/y/z> = Scale Automatically all other axes values by the LARGEST
- value of axis x OR axis y OR axis z -- commonly called "scale to
- fit"; this option takes the ratio of the largest value in the data
- of the specified axis to the largest value in the data of the other
- axis and multiplies all values in the data of the other axis by
- this ratio; the values in the data of the specified axis are left
- unchanged; if 3-D option is specified, this procedure would be
- performed twice, once for each "other" axis
-
-
- Some general comments:
-
- 1. Defaults are automatically in effect unless explicitly overridden by
- turning on an option. Therefore, if a default is desired, you need
- not list it as an option. The exception to this occurs when proces-
- sing multiple files and you wish to return subsequent files to the
- defaults. If any option is turned on, it remains in effect for all
- files until "turned off" by either: specifying the default(s) or
- changing a parameter (in the case of "-b", "-s", and "-x"). See the
- multiple file examples in Section 4 for further clarification.
-
-
-
- ASC-SCR 2.1 Page 7
- SECTION 3
-
-
- 2. If more than one option is used, list them on the command line in the
- same order as tabulated above (see examples below). If this is not
- done, you may get error or warning messages, or results that you did
- not expect.
-
- 3. Input filename(s) may include full path specifications and/or wildcard
- symbols, allowing you great flexibility. Although the path may be
- specified for the input file, the output script file will always be
- sent to the current subdirectory. Wildcard symbols allow you to auto-
- matically process a group of input data files without having to enter
- each name separately. Output filename(s) will always have the same
- prefix as the input filename(s), but the extension will be the
- standard AutoCAD script file ".scr"; unless specified otherwise with
- the "-x" option.
-
- 4. The options "-b", "-s", or "-x" require additional data for correct
- processing. The "< >" data may follow the option letter with OR
- without a space. For example, "-bdwg_blk" and "-b dwg_blk" will both
- insert the drawing block "dwg_blk".
-
- 5. Options may be strung together after a single delimiter (i.e.
- "-i3su10"), but if options "-b", "-s", or "-x" are followed by
- another option, there MUST be a space and another delimiter (i.e.
- "-i3bgadget -su10 -xdap").
-
- 6. As mentioned above, when using the "-b" option the program checks for
- existence of the specified block. It takes the block name supplied,
- including any path, appends the ".dwg" extension, and checks for
- existence of this file. If not found, the program will exit with a
- fatal error because under normal circumstances, we assume that the
- user will have already created the block to be inserted. However,
- there are circumstances where the drawing block may not exist at all
- yet, or may be on a different computer or even stored on a floppy.
- Therefore, to allow the program to run successfully when specifying
- a block that "doesn't exist", use the "-i" option to ignore this
- error. That will allow you to build your script file to insert any
- block. At present, all blocks are inserted at x & y scale both equal
- to 1 and angle of rotation equal to 0.
-
- 7. In the event of some fatal error, the program will terminate proces-
- sing graciously, even if you are using the "-i" option. The primary
- fatal errors include errors resulting from file I/O and attempting to
- overwrite an existing script file. Data processing errors are the
- only kind that can be ignored by using "-i". This type of non-fatal
- error primarily includes: most non-numeric data; no y value; no z
- value when using "-3" option; and non-existent drawing block when
- using "-b". BE CAREFUL when using the "-i" option because if bad data
- is encountered, a valid script file will be created, but it will have
- skipped those coordinates that contained bad data! To assist you in
- finding the bad data in your input file, a warning message will appear
- on the screen and the "guilty" data will be echoed to the screen.
-
- Although we have consistently used lower case in all of our examples, this
- program is not case sensitive. You may use upper or lower case. (You may
- even mix upper and lower case, if you wish).
-
-
- ASC-SCR 2.1 Page 8
- SECTION 4
-
- Examples
-
- Following are a number of examples to illustrate the basics of the ASC-SCR
- options.
-
- 1. asc-scr myfile.dat
-
- The script file "myfile.scr" will be created with 2-D coordinates
- making a polyline (i.e. the defaults were used).
-
- 2. asc-scr myfile1.dat myfile2.txt myfile3.out .....
-
- Gives same result as example 1, but for as many files as there are
- listed on the command line. To do the same thing, with much less
- typing, use " asc-scr myfile?.* " and take advantage of wildcards.
-
- 3. asc-scr -bwidget -su2 myfile.dat
-
- The created script file will insert the block "widget.dwg". Both the
- x & y values at every coordinate will be multiplied by 2.
-
- 4. asc-scr -b widget -su2 myfile1.dat -sx10 myfile2.txt
-
- This example creates two script files that will insert the block
- "widget.dwg". The first scales x & y values by 2 (if there are z
- values, they will be ignored because the "-3" switch wasn't used).
- The second scales only x values by 10.
-
- 5. asc-scr myfile1.dat -b widget -sx2 myfile2.txt -qn myfile3.out
-
- This example creates three script files. The first will have defaults
- (a 2-D polyline). The second will insert the block "widget.dwg",
- scaling all x values by 2, and any non-fatal errors would only cause
- a warning. The third script file will be created with nodes only
- inserted at the coordinates, but errors would cause processing to
- abort. Note that x values will also be multiplied by 2 because the
- switch is still in effect.
-
- 6. asc-scr -i3bnewblock -xtmp myfile?.*
-
- Script files will be created (with 3-D coordinates, inserting the
- block "newblock.dwg") from all files which match the wildcard spec.
- The normal extension of ".scr" would be replaced with ".tmp" for all
- files created. The "-i" option allows processing to continue since
- the block doesn't exist yet.
-
- 7. asc-scr -i3nx1sc datfile.1 -q2pg datfile.2
-
- Script file "datfile.1sc" will be created with nodes only at 3-D co-
- ordinates, (and giving a warning, rather than aborting, if any 'z'
- not found). Then the file "datfile.scr" would be created, using all
- defaults (quit on error, 2-D points, polyline creation, and ".scr"
- extension). This example illustrates the instance where the defaults
- must be listed as options because of what you previously specified.
- A better way to get the same results would be the following:
- " asc-scr datfile.2 -i3nx1sc datfile.1 ".
-
-
- ASC-SCR 2.1 Page 9
- SECTION 5
-
- Questions or Problems
-
- If you have problems with ASC-SCR, please read this manual carefully first
- to make sure you do understand everything. To the best of our knowledge,
- we have provided a problem-free product but sometimes things can be missed.
- If you think you have found a problem, please take the time to contact us
- and explain your problem. All registered users will be informed of any
- problems. Errors will be corrected. Make sure that you include the
- following information to help us evaluate the problem:
-
- 1. What version of ASC-SCR you are using
- 2. The precise command line executed that causes the problem
- 3. Any error message(s) generated by the program
- 4. Machine type, memory, monitor type, hardware description
- 5. Any application executed before ASC-SCR
- 6. Version of DOS you are using
- 7. Where, when, and how you obtained ASC-SCR
- 8. Your address and telephone number (when corresponding)
-
- We only maintain the most current release of our products. If you are a
- registered user, you will automatically receive any error corrections and
- minor enhancements to the product. This will often take care of the
- problem.
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- ASC-SCR 2.1 Page 10
-
-
- ----------------end-of-author's-documentation---------------
-
- Software Library Information:
-
- This disk copy provided as a service of
-
- Public (software) Library
-
- We are not the authors of this program, nor are we associated
- with the author in any way other than as a distributor of the
- program in accordance with the author's terms of distribution.
-
- Please direct shareware payments and specific questions about
- this program to the author of the program, whose name appears
- elsewhere in this documentation. If you have trouble getting
- in touch with the author, we will do whatever we can to help
- you with your questions. All programs have been tested and do
- run. To report problems, please use the form that is in the
- file PROBLEM.DOC on many of our disks or in other written for-
- mat with screen printouts, if possible. PsL cannot debug pro-
- programs over the telephone, though we can answer questions.
-
- Disks in the PsL are updated monthly, so if you did not get
- this disk directly from the PsL, you should be aware that the
- files in this set may no longer be the current versions. Also,
- if you got this disk from another vendor and are having prob-
- lems, be aware that some files may have become corrupted or
- lost by that vendor. Get a current, working disk from PsL.
-
- For a copy of the latest monthly software library newsletter
- and a list of the 3,000+ disks in the library, call or write
-
- Public (software) Library
- P.O.Box 35705 - F
- Houston, TX 77235-5705
-
- Orders only:
- 1-800-2424-PSL
- MC/Visa/AmEx/Discover
-
- Outside of U.S. or in Texas
- or for general information,
- Call 1-713-524-6394
-
- PsL also has an outstanding
- catalog for the Macintosh.
-
-